From: Stuart Prescott Date: Sun, 19 Jul 2026 02:42:56 +0000 (+1000) Subject: Add versioned dependencies to python3-dev X-Git-Tag: archive/raspbian/6.11.2-2+rpi1^2~21 X-Git-Url: https://dgit.raspbian.org/%22http://www.example.com/cgi/%22/%22http:/www.example.com/cgi/%22?a=commitdiff_plain;h=1a676541f8e0079db99d1267846d15a75daae381;p=pyside6.git Add versioned dependencies to python3-dev Closes: #1141467 --- diff --git a/debian/control b/debian/control index e17aac02..455d48c0 100644 --- a/debian/control +++ b/debian/control @@ -138,9 +138,9 @@ Section: libdevel Architecture: any Depends: libshiboken6-py3-6.10 (= ${binary:Version}), - python3-dev, shiboken6 (= ${source:Version}), ${misc:Depends}, + ${pyside6:python3-default-dev}, ${shlibs:Depends}, Description: CPython bindings generator for C++ libraries (development files) Shiboken6 is a bindings generator for C++ libraries that outputs CPython @@ -192,6 +192,7 @@ Section: devel Depends: python3-pyside6.qtcore, ${misc:Depends}, + ${pyside6:python3-default-dev}, ${python3:Depends}, ${shlibs:Depends}, Description: development tools for PySide6 (lupdate) diff --git a/debian/rules b/debian/rules index 02c49b57..36436952 100755 --- a/debian/rules +++ b/debian/rules @@ -30,6 +30,10 @@ PYBUILD_BUILD_ARGS = --skip-packaging --verbose-build PYBUILD_BUILD_ARGS += --parallel=$(or $(DEB_BUILD_OPTION_PARALLEL),$(DEB_BUILD_OPTION_PARALLEL),1) PYBUILD_INSTALL_ARGS = --reuse-build --verbose-build +# default Python interpreter (and the next version) for dependencies +PYVER := $(shell py3versions -d -v) +NEXTPYVER := $(shell echo $(PYVER) | awk 'BEGIN{FS="." }{print $$1 "." $$2 + 1}') + ## Package compilation options # 1. if sccache is installed then use it @@ -136,3 +140,12 @@ else --test-args '{interpreter} testrunner.py test --buildno=-1' endif endif + + +execute_before_dh_gencontrol: + # Generate a versioned dependency on python3-dev that matches the + # current default Python interpreter only. These -dev packages rely + # on `python3` as a command and point at the versioned paths to the + # headers for that specific version + echo "pyside6:python3-default-dev=python3-dev (>= $(PYVER)), python3-dev (<< $(NEXTPYVER)~)" >> debian/libshiboken6-dev.substvars + echo "pyside6:python3-default-dev=python3-dev (>= $(PYVER)), python3-dev (<< $(NEXTPYVER)~)" >> debian/pyside6-tools.substvars